import React,{Component} from 'react';
import {Platform, StyleSheet,ScrollView,Text, View,TouchableOpacity, Alert,Image, TextInput,Picker } from 'react-native';
import DatePicker from 'react-native-datepicker';

export default class attendance extends Component{
    static navigationOptions = {
        headerStyle:{
            backgroundColor:'#d04542',
            height:50,
        },
        headerTintColor:'white',
    };
	constructor(props){
    	super(props)
    	this.state = {
    		datetime: '', //用来存取时间的
    	}
    }
	render(){
		const { navigation } = this.props;
		return(
		    <ScrollView style={styles.ScrollView}>
				<View style={styles.List}>
               		<Picker style={styles.Pickers} selectedValue= {this.state.language} onValueChange= {lang=> {this.setState( {language: lang})}} mode="dialog">
					 	<Picker.Item label='省/直辖市' value='省/直辖市'/>
					 	<Picker.Item label='北京' value='呼和浩特'/>
					 	<Picker.Item label='河北' value='包头'/>
					  	<Picker.Item label='山西' value='东升'/> 
					  	<Picker.Item label='内蒙古' value='集宁'/> 
					</Picker> 
               </View>
               <View style={styles.List}>
               		<Picker style={styles.Pickers} selectedValue= {this.state.language} onValueChange= {lang=> {this.setState( {language: lang})}} mode="dialog">
					 	<Picker.Item label='市/区' value='市/区'/>
					 	<Picker.Item label='呼和浩特' value='呼和浩特'/>
					 	<Picker.Item label='包头' value='包头'/>
					  	<Picker.Item label='东升' value='东升'/> 
					  	<Picker.Item label='集宁' value='集宁'/> 
					</Picker> 
               </View>
                <View style={styles.List}>
               		<Picker style={styles.Pickers} selectedValue= {this.state.language} onValueChange= {lang=> {this.setState( {language: lang})}} mode="dialog">
					 	<Picker.Item label='医院' value='医院'/>
					 	<Picker.Item label='第一医院' value='呼和浩特'/>
					 	<Picker.Item label='第二医院' value='包头'/>
					  	<Picker.Item label='第三医院' value='东升'/> 
					  	<Picker.Item label='第四医院' value='集宁'/> 
					</Picker> 
               </View>
               <View style={styles.List}>
               		<Picker style={styles.Pickers} selectedValue= {this.state.language} onValueChange= {lang=> {this.setState( {language: lang})}} mode="dialog">
					 	<Picker.Item label='科室' value='科室'/>
					 	<Picker.Item label='男科' value='呼和浩特'/>
					 	<Picker.Item label='女科' value='包头'/>
					  	<Picker.Item label='骨科' value='东升'/> 
					  	<Picker.Item label='牙科' value='集宁'/> 
					</Picker> 
               </View>
               <View style={{padding:10}}>
			        <TouchableOpacity style={{height:40}}
			        	onPress={()=>{ 
							navigation.navigate("onlineDoctor")
						}}
			        >
			      		<Text style={styles.btn}>提交</Text>
			    	</TouchableOpacity>
		    	</View>
         	</ScrollView>
		);
	}
}
const styles = StyleSheet.create({
	ListTitle:{
		flex:2,lineHeight: 50 ,fontSize: 18,
	},
	Pickers:{
		flex:4,
	},
	List:{
		flexDirection:'row',marginLeft:10,marginTop:5,borderBottomWidth:1,borderBottomColor: "#D4D4D4",
	},
	btn:{
		width:"100%",backgroundColor:'#D04542',borderRadius:2,
	  	lineHeight: 40 ,color: 'white',textAlign: 'center',
	},
});



				  